package xyz.xuminghai.javafx_learn.scene.shape;

import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.layout.BorderPane;
import javafx.scene.shape.Circle;
import javafx.stage.Stage;

/**
 * 2023/8/12 16:49 星期六<br/>
 * Circle类创建一个具有指定半径和中心位置（以像素为单位）的新圆。
 *
 * @author xuMingHai
 */
public class CircleApp extends Application {

    private final BorderPane root = new BorderPane();


    public static void main(String[] args) {
        Application.launch(args);
    }

    @Override
    public void init() {
        Circle circle = new Circle(50.0);
        root.setCenter(circle);
    }

    public void start(Stage primaryStage) {
        primaryStage.setTitle(getClass().getSimpleName());
        Scene scene = new Scene(root, 800, 600);
        primaryStage.setScene(scene);
        primaryStage.show();
    }
}
